package club.zhaoliang.study.blockcanary;

import androidx.appcompat.app.AppCompatActivity;

import android.os.Bundle;
import android.os.SystemClock;
import android.view.View;

import club.zhaoliang.study.R;

public class BlockCanaryActivity extends AppCompatActivity {

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_block_canary);
        
        findViewById(R.id.tvBlock2S).setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View view) {
                sleep();
            }
        });


    }


    private void sleep() {
        try {
            Thread.sleep(2000);
        } catch (InterruptedException e) {
            e.printStackTrace();
        }
    }
}
